﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Linq;
using System.Threading.Tasks;
using System.Windows.Forms;
using DevExpress.XtraEditors;
using BUS;
using Public;

namespace QuanLyKhoHangVatTu
{
    public partial class ChiTietNhomVatTuHangHoa : DevExpress.XtraEditors.XtraForm
    {
        NhomVatTu_BUS nvt_bus = new NhomVatTu_BUS();
        NhomVatTu_PB nvt_pb = new NhomVatTu_PB();
        Flag_PB flag_pb = new Flag_PB();
        public ChiTietNhomVatTuHangHoa()
        {
            InitializeComponent();
        }

        private void ChiTietNhomVatTuHangHoa_Load(object sender, EventArgs e)
        {
            Flag_PB.Flag = 1;
            gridNhomVatTu.DataSource = nvt_bus.LayDSNhomVatTu();
        }
     
        private void gridNhomVatTu_Click(object sender, EventArgs e)
        {

        }

        private void gridView1_RowCellClick(object sender, DevExpress.XtraGrid.Views.Grid.RowCellClickEventArgs e)
        {
            
        }

        private void gridView1_FocusedRowChanged(object sender, DevExpress.XtraGrid.Views.Base.FocusedRowChangedEventArgs e)
        {
            NhomVatTu_PB.MaNhomVatTu = gridView1.GetRowCellValue(e.FocusedRowHandle, "MANHOMVATTU").ToString();
            NhomVatTu_PB.TenNhomVatTu = gridView1.GetRowCellValue(e.FocusedRowHandle, "TENNHOMVATTU").ToString();
        }
        
    }
}